	
	<div id="page-content">
			<div class="col-lg-12">
		        <div class="panel">
		            <div class="panel-heading">
		                <h3 class="panel-title">
		                	#@installPJaxGoBackBtn()
		                	添加
		                </h3>
		            </div>
		            <form id="editForm" class="panel-body form-horizontal form-padding">
						<input type="hidden"  name="dctResourceCar.id" class="form-control" value="#(o?o.id:'')">
			                <div class="form-group">
			                    <label class="col-md-2 control-label">车牌号</label>
			                    <div class="col-md-9">
			                        <input type="text"  name="dctResourceCar.num" class="form-control"  value="#(o?o.num:'')" #if(view=='detail') readonly #end>
			                    </div>
			                </div>
			                <div class="form-group">
			                    <label class="col-md-2 control-label">品牌</label>
			                    <div class="col-md-4">
			                        <input type="text"  name="dctResourceCar.brand" class="form-control"  value="#(o?o.brand:'')" #if(view=='detail') readonly #end>
			                    </div>
			                    <label class="col-md-1 control-label">型号</label>
			                    <div class="col-md-4">
			                        <input type="text"  name="dctResourceCar.version" class="form-control"  value="#(o?o.version:'')" #if(view=='detail') readonly #end>
			                    </div>
			                </div>
			                <div class="form-group">
			                    <label class="col-md-2 control-label">购买时间</label>
			                    <div class="input-group date form_datetime col-md-4" style="float:left">
				                    <input type="text"  name="dctResourceCar.buy_time" class="form-control"  value="#(o?o.buy_time:'')" readonly>
									<span class="input-group-addon"><span class="glyphicon glyphicon-th"></span></span>
				                </div>
				                <label class="col-md-1 control-label">颜色</label>
			                    <div class="col-md-4">
			                        <input type="text"  name="dctResourceCar.color" class="form-control"  value="#(o?o.color:'')" #if(view=='detail') readonly #end>
			                    </div>
			                </div>
			                <div class="form-group">
			                    <label class="col-md-2 control-label">简述</label>
			                    <div class="col-md-9">
			                        <textarea rows="8" name="dctResourceCar.des" class="form-control" #if(view=='detail') readonly #end>#(o?o.des:'')</textarea>
			                    </div>
			                </div>
				                
			            	<div class="panel-footer">
			                    <div class="row">
			                        <div class="col-sm-8 col-sm-offset-3">
			                            <button class="btn btn-warning" type="reset" #if(view=='detail') disabled #end>重置</button>
			                            <button class="btn btn-primary" type="submit"  #if(view=='detail') disabled #end>保存</button>
			                        </div>
			                    </div>
			                </div>
		            </form>
		        </div>
		    </div>
	</div>
	<script>
		function save(){
			var data = common_ajax.ajaxFunc("/admin/oa/dct/resourcecar/save", $('#editForm').serialize(), "json", null);
			if(data.success){
				pointLion.alertMsg("保存成功!" , "success" , "small" , function(){
					location.href = ctx+'/admin/oa/dct/resourcecar/getListPage';//跳转到列表页
				});
			}
		}
		$(document).ready(function() {
			$('.form_datetime').datetimepicker({weekStart: 1,todayBtn:  1,autoclose: 1,language:  'zh-CN',todayHighlight: 1,startView: 2,forceParse: 0,showMeridian: 1});
			$('#editForm').bootstrapValidator({
	            fields: {
	            }
	        }).on("success.form.bv", function (e) {
	            save();
	            return false;//阻止表单跳转
	        });
		});
	</script>